import request from '@/utils/request'

export default{
  getHospSetList(current,limit,searchObj){
    return request({
      url: `/admin/hosp/hospitalSet/findPage/${current}/${limit}`,
      method: 'post',
      data: searchObj //使用json形式
    })
  },
  //删除医院设置方法
  deleteHospSet(id) {
    return request ({
      url: `/admin/hosp/hospitalSet/${id}`,
      method: 'delete'
    })
  },
//批量删除的方法
  batchHospSet(idList){
    return request({
       url: `/admin/hosp/hospitalSet/batchHospitalSet`,
       method: "delete",
       data: idList
    })

  },
  //锁定
  lockHospSet(id,status){
    return request({
      url:`/admin/hosp/hospitalSet/lockHospitalSet/${id}/${status}`,
      method:'put'
    })
  },
  //添加医院设置
  saveHospSet(hospitalSet){
    return request({
      url:`/admin/hosp/hospitalSet/saveHospitalSet`,
      method:"post",
      data: hospitalSet
    })
  },
  //医院设置id查询功能
  getHospSet(id){
    return request({
      url:`/admin/hosp/hospitalSet/getHospitalSet/${id}`,
      method:"post"
    })
  },
  //修改功能
  updateHospSet(hospitalSet){
    return request({
      url:`/admin/hosp/hospitalSet/updatHospitalSet`,
      method:"Post",
      data:hospitalSet
    })
  }
}
